# @Time : 2020/7/22 16:08
# @Author : Fioman 
# @Phone : 13149920693

import cv2 as cv
import numpy as np
from 第二周_opencv轻松入门.第06章_图像平滑处理.image_show_tools import image_show

img = cv.imread("bilateral.jpg",cv.IMREAD_GRAYSCALE)

imgBlurred = cv.blur(img,(5,5))
imgMedianBlurred = cv.medianBlur(img,5)
imgGaussianBlurred = cv.GaussianBlur(img,(5,5),0,0)
imgBilateralBlurred = cv.bilateralFilter(img,5,50,50)

image_show("Original",img,False)
image_show("imgBlurred",imgBlurred,False)
image_show("imgMedianBlurred",imgMedianBlurred,False)
image_show("imgGaussianBlurred",imgGaussianBlurred,False)
image_show("imgBilateralBlurred",imgBilateralBlurred,False)